import 'dart:typed_data';

///QQ授权-分享  参数
class QQSDKParamMap {
  //QQ开发者账号ID
  String? appId;

  // iOS平台需要Universal Links
  String? iOSUniversalLinks;

//  SCOPE = “get_simple_userinfo,add_topic”；所有权限用“all”
  String? scope;

  //QQ(QQ好友/QZone)
  String? targetScene;

  //要分享的标题
  String? title;

  //要分享的摘要
  String? summary;

  //目标链接
  String? targetUrl;

  //图片路径
  List<String>? imageUri;

  // 网络图片地址
  String? networkImageUrl;

  //应用名称
  String? appName;

  String? musicUrl;

  // 内存图片
  Uint8List? imageData;

  QQSDKParamMap({
    this.appId,
    this.iOSUniversalLinks,
    this.scope,
    this.targetScene,
    this.title,
    this.summary,
    this.targetUrl,
    this.imageUri,
    this.networkImageUrl,
    this.appName,
    this.musicUrl,
    this.imageData,
  });

  QQSDKParamMap.fromMap(Map map)
      : appId = map["appId"],
        iOSUniversalLinks = map["iOSUniversalLinks"],
        scope = map["scope"],
        targetScene = map["targetScene"],
        title = map["title"],
        summary = map["summary"],
        targetUrl = map["targetUrl"],
        imageUri = map["imageUri"],
        networkImageUrl = map["networkImageUrl"],
        appName = map["appName"],
        musicUrl = map["musicUrl"],
        imageData = map["imageData"];

  Map<String, dynamic> toMap() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data["appId"] = appId;
    data["iOSUniversalLinks"] = iOSUniversalLinks;
    data["scope"] = scope;
    data["targetScene"] = targetScene;
    data["title"] = title;
    data["summary"] = summary;
    data["targetUrl"] = targetUrl;
    data["imageUri"] = imageUri;
    data["networkImageUrl"] = networkImageUrl;
    data["appName"] = appName;
    data["musicUrl"] = musicUrl;
    data["imageData"] = imageData;

    return data;
  }
}
